<html>
<body bgcolor= "lightgray">
<h1 style="text-align: center;"><font size= "6"><b>To add to this list, click <a href='addlist.php'>here</a> <b><br><br>

Click on edit/delete to alter/remove a specific OPD CASE.  
 </font> </a><br></h1>


<?php

include ("adb.php");

 $obj = new adb();
 $obj->connect();
    if(!$obj->query("select * from opd_cases")){
        echo "Error";   
		echo  mysql_error($obj -> link);
		exit();
    }
?>
<table border ="1" align= "center" bgcolor="darkgray">
<tr>
			<td>OPD CaseID </td>
			<td align= "center">OPD CaseName</td>
			<td align= "center">OPD Category </td> 
			<td align= "center"> EDIT</td>
			<td align= "center"> DELETE </td>
		</tr>	
<?php

$row= $obj -> fetch();
	while($row){
		echo "<tr>";
			$opd_case_id=$row['opd_case_id'];
			echo "<td>".$row['opd_case_id'];
				echo "</td>";
				
				//$opd_case_id=$row['opd_case_name'];
				echo "<td width = '350'>".$row['opd_case_name'];
				echo "</td>";
				
				//$opd_case_id=$row['opd_case_category'];
				echo "<td>".$row['opd_case_category'];
				echo "</td>";
			  
			  
			   echo "<td>";
			
			echo "<a href='opd_case_update.php?opd_case_id=$opd_case_id'>edit</a>";
			
			echo "<td>";
			echo "<a href='delete_opdcase.php?opd_case_id=$opd_case_id'>delete</a>";
			
		echo "</td></tr>";
		$row = $obj -> fetch();
		}


?>
</table>
</body>
</html>